home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Plus 1997 #3
/
Amiga Plus CD - 1997 - No. 03.iso
/
pd
/
programmierung
/
alienbreed3d2_src
/
cheesesauce
/
pauseopts
< prev
next >
Wrap
Text File
|
1997-01-31
|
6KB
|
409 lines
; Options:
; FAST buffer on/off
; Floors Gouraud/Textured/Plain
;
; FIRST HALVE SCREEN BRIGHTNESS
; move.l frompt,pausept
; move.l olddrawpt,d3
; add.l #10,d3
; move.l d3,pbuffpt
; bsr DRAWPAUSESCRN
; move.l drawpt,d0
; move.l olddrawpt,drawpt
; move.l d0,olddrawpt
; move.l d0,$dff084
; move.l drawpt,a3
; move.l COPSCRNBUFF,a3
; adda.w #10,a3
; move.l a3,frompt
; add.l #104*4*40,a3
; move.l a3,midpt
;waitfortop:
; btst.b #0,intreqrl(a6)
; beq waitfortop
; move.w #$1,intreq(a6)
.waitpress
; bsr CHANGEPOPTS
cmp.b #'s',mors
beq.s .otherk
tst.b PLR1JOY
beq.s .NOJOY
jsr _ReadJoy1
bra .thisk
.otherk:
tst.b PLR2JOY
beq.s .NOJOY
jsr _ReadJoy2
.thisk:
.NOJOY:
tst.b $19(a5)
bne.s .unp
btst #7,$bfe001
bne.s .waitpress
.unp:
.wr2:
cmp.b #'s',mors
beq.s .otherk2
tst.b PLR1JOY
beq.s .NOJOY2
jsr _ReadJoy1
bra .thisk2
.otherk2:
tst.b PLR2JOY
beq.s .NOJOY2
jsr _ReadJoy2
.thisk2:
.NOJOY2:
tst.b $19(a5)
bne.s .wr2
btst #7,$bfe001
beq.s .wr2
rts
CHECKUPDOWN
btst #1,$dff00c
sne d0
btst #1,$dff00d
sne d1
btst #0,$dff00c
sne d2
btst #0,$dff00d
sne d3
eor.b d0,d2
eor.b d1,d3
cmp.b #'s',mors
beq.s .slavechk
tst.b PLR1JOY
bne.s .nofing
bra.s .maschk
.slavechk:
tst.b PLR2JOY
bne.s .nofing
.maschk:
moveq #0,d6
move.l #KeyMap,a5
move.b forward_key,d6
tst.b (a5,d6.w)
sne d0
or.b d0,d2
move.b backward_key,d6
tst.b (a5,d6.w)
sne d1
or.b d1,d3
.nofing:
rts
CHANGEPOPTS:
bsr CHECKUPDOWN
tst.b d3
beq.s nobotchange
move.w BOTPOPT,d0
addq #1,d0
and.w #3,d0
move.w d0,BOTPOPT
clr.b ANYFLOOR
clr.b GOURSEL
st CLRNOFLOOR
move.l #SimpleFloorLine,THEFLOORLINE
cmp.w #2,d0
bgt.s .nofloor
beq.s .plainfloor
tst.w d0
bgt.s .textureonly
st GOURSEL
.textureonly
move.l #FloorLine,THEFLOORLINE
.plainfloor
st ANYFLOOR
clr.b CLRNOFLOOR
.nofloor:
muls #12,d0
add.l #FLOOROPTS,d0
move.l d0,a0
move.l #FLOOROPTLINE,a1
bsr PUTINPLINE
bsr DRAWPAUSESCRN
billythe
bsr CHECKUPDOWN
tst.b d3
bne.s billythe
nobotchange:
tst.b d2
beq notopchange
move.w TOPPOPT,d0
addq #1,d0
and.w #3,d0
move.w d0,TOPPOPT
move.b STEROPT(pc,d0.w*2),STEREO
move.b STEROPT+1(pc,d0.w*2),d1
move.b d1,Prefsfile+1
bra pastster
STEROPT:
dc.b 0,4
dc.b $FF,4
dc.b 0,8
dc.b $ff,8
pastster:
cmp.b #'4',d1
seq.s CHANNELDATA+8
seq.s CHANNELDATA+12
seq.s CHANNELDATA+24
seq.s CHANNELDATA+28
move.w #$f,$dff000+dmacon
move.l #null,$dff0a0
move.w #100,$dff0a4
move.w #443,$dff0a6
move.w #63,$dff0a8
move.l #null2,$dff0b0
move.w #100,$dff0b4
move.w #443,$dff0b6
move.w #63,$dff0b8
move.l #null4,$dff0c0
move.w #100,$dff0c4
move.w #443,$dff0c6
move.w #63,$dff0c8
move.l #null3,$dff0d0
move.w #100,$dff0d4
move.w #443,$dff0d6
move.w #63,$dff0d8
move.w #$820f,$dff000+dmacon
muls #12,d0
add.l #SOUNDOPTS,d0
move.l d0,a0
move.l #SOUNDOPTLINE,a1
bsr PUTINPLINE
bsr DRAWPAUSESCRN
billythetop
bsr CHECKUPDOWN
tst.b d2
bne.s billythetop
notopchange
rts
THEFLOORLINE: dc.l FloorLine
USECOPBUFFER: dc.w 0
TOPPOPT: dc.w 0
BOTPOPT: dc.w 0
ANYFLOOR: dc.w 0
PUTINPLINE:
moveq #11,d7
.pppp
move.b (a0)+,(a1)+
dbra d7,.pppp
rts
pbuffpt: dc.l 0
pausept: dc.l 0
DRAWPAUSESCRN:
move.l #PAUSEFONT,a0
move.l #PAUSETXT,a1
move.l pausept,a2
move.l pbuffpt,a3
bsr DRAWPAUSEBLOCK
add.w #4,a2
add.w #4,a3
bsr DRAWPAUSEBLOCK
add.w #4,a2
add.w #4,a3
bsr DRAWPAUSEBLOCK
rts
DRAWPAUSEBLOCK:
move.w #3,d0
.across:
moveq #0,d1
moveq #0,d2
moveq #9,d3
moveq #0,d5
.down:
moveq #0,d4
move.b (a1,d2.w),d4
add.w #12,d2
sub.b #'A',d4
bge .itsalet
moveq #7,d6
.dospc:
move.w (a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
move.w d1,(a2,d5.l)
move.w 4(a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
move.w d1,4(a2,d5.l)
move.w 8(a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
move.w d1,8(a2,d5.l)
move.w 12(a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
move.w d1,12(a2,d5.l)
move.w 16(a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
move.w d1,16(a2,d5.l)
move.w 20(a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
move.w d1,20(a2,d5.l)
move.w 24(a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
move.w d1,24(a2,d5.l)
move.w 28(a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
move.w d1,28(a2,d5.l)
add.l #104*4,d5
dbra d6,.dospc
bra .nolet
.itsalet:
asl.w #7,d4
lea (a0,d4.w),a5
moveq #7,d6
.dolet:
move.w (a5)+,d1
bne.s .okpix1
move.w (a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
.okpix1:
move.w d1,(a2,d5.l)
move.w (a5)+,d1
bne.s .okpix2
move.w 4(a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
.okpix2:
move.w d1,4(a2,d5.l)
move.w (a5)+,d1
bne.s .okpix3
move.w 8(a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
.okpix3:
move.w d1,8(a2,d5.l)
move.w (a5)+,d1
bne.s .okpix4
move.w 12(a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
.okpix4:
move.w d1,12(a2,d5.l)
move.w (a5)+,d1
bne.s .okpix5
move.w 16(a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
.okpix5:
move.w d1,16(a2,d5.l)
move.w (a5)+,d1
bne.s .okpix6
move.w 20(a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
.okpix6:
move.w d1,20(a2,d5.l)
move.w (a5)+,d1
bne.s .okpix7
move.w 24(a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
.okpix7:
move.w d1,24(a2,d5.l)
move.w (a5)+,d1
bne.s .okpix8
move.w 28(a3,d5.l),d1
and.w #$eee,d1
lsr.w #1,d1
.okpix8:
move.w d1,28(a2,d5.l)
add.l #104*4,d5
dbra d6,.dolet
.nolet:
dbra d3,.down
add.w #4*8,a3
add.w #4*8,a2
addq #1,a1
dbra d0,.across
rts
PAUSETXT:
; 012345678901
dc.b ' ' 0
dc.b ' ' 1
dc.b 'SFX QUALITY' 2
SOUNDOPTLINE:
dc.b ' ' 3
dc.b ' ' 4
dc.b 'FLOOR DETAIL' 5
FLOOROPTLINE:
dc.b ' GOURAUD ' 6
dc.b ' ' 7
dc.b ' ' 8
dc.b ' ' 9
SOUNDOPTS:
dc.b 'FOUR CH MONO'
dc.b ' FOUR CH ST '
dc.b 'EIGHT C MONO'
dc.b ' EIGHT C ST '
FLOOROPTS:
dc.b ' GOURAUD '
dc.b ' TEXTURED '
dc.b 'PLAIN SHADED'
dc.b ' NONE '
PAUSEFONT:
incbin "ab3:includes/PAUSEFONT"